﻿using System.Collections.Generic;
using System.Linq;

namespace Cms.Domain
{
    public class TemplatablePlugin : Plugin
    {
        private IList<PluginTemplate> _templates;

        public TemplatablePlugin()
        {
            _templates = new List<PluginTemplate>();
        }

        public virtual IList<PluginTemplate> Templates
        {
            get { return _templates; }
            set { _templates = value; }
        }
        
        public virtual IList<PluginTemplate> GetTemplates(int siteID)
        {
            return _templates.Where(pt => pt.Site.ID == siteID).ToList();
        }
    }
}